package com.twotiger.and.bean;

import android.os.Parcel;
import android.os.Parcelable;

import com.twotiger.and.util.StringUtils;

/**
 * Created by victor on 2014/10/15 0015.
 */
public class Bank implements Parcelable {
    private String nid;  //银行标识 
    private String name; //中文名称
    private String code; //
    private String dayAmt; //单日
    private String perAmt; //单笔
    private String bankLogo;
    
    private String noCardPay; //无卡支付   V2.5新增    1:需要;0:不需要
    
    
    public String getNoCardPay() {
        return noCardPay;
    }

    public void setNoCardPay(String noCardPay) {
        this.noCardPay = noCardPay;
    }

    public String getBankLogo() {
        return bankLogo;
    }

    public void setBankLogo(String bankLogo) {
        this.bankLogo = bankLogo;
    }

    public static Parcelable.Creator<Bank> getCreator() {
        return CREATOR;
    }

    public Bank() {
        super();
        // TODO Auto-generated constructor stub
    }

    public String getDayAmt() {
        return dayAmt;
    }

    public void setDayAmt(String dayAmt) {
        this.dayAmt = dayAmt;
    }

    public String getPerAmt() {
        return perAmt;
    }

    public void setPerAmt(String perAmt) {
        this.perAmt = perAmt;
    }

    public String getNid() {
        if (StringUtils.isEmpty(nid)) {
            return " ";
        }
        return nid;
    }

    public void setNid(String nid) {
        this.nid = nid;
    }

    public String getName() {
        if (StringUtils.isEmpty(nid)) {
            return " ";
        }
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    @Override
    public int describeContents() {
        // TODO Auto-generated method stub
        return 0;
    }

    public static final Parcelable.Creator<Bank> CREATOR = new Creator<Bank>() {

        @Override
        public Bank[] newArray(int size) {
            // TODO Auto-generated method stub
            return new Bank[size];
        }

        @Override
        public Bank createFromParcel(Parcel in) {
            // TODO Auto-generated method stub
            return new Bank(in);
        }
    };

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(nid);
        dest.writeString(name);
        dest.writeString(code);
        dest.writeString(dayAmt);
        dest.writeString(perAmt);
    }

    public Bank(Parcel in) {
        nid = in.readString();
        name = in.readString();
        code = in.readString();
        dayAmt = in.readString();
        perAmt = in.readString();
    };
}
